/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package fr.ove.clientserver.events;

/**
 *
 * @author Mr.Sam
 */
import java.util.EventObject;
import java.net.Socket;

/**
* The event sent by a socket server.
*/
public class SocketServerEvent extends EventObject {
    /**
    * The socket the instance encapsulates.
    */
    private Socket socket;
    
    /**
    * The constructor.
    * @param src the source of the event.
    */
    public SocketServerEvent(Object src) {
        super(src);
    }
    
    /**
    * Sets the socket to the instance.
    * @param socket the socket to encapsulate.
    */
    public void setSocket(Socket socket) {
        this.socket = socket;
    }
    
    /**
    * Returns the socket encapsulated in the instance.
    */
    public Socket getSocket() {
        return socket;
    }
}
    
    